#!/bin/bash
PORT_C=`ss -lntp|grep 80|wc -l`
PS_C=`ps aux|grep nginx|grep -v grep`
if [ $PORT_C -eq 0 -o $PS_C -eq 0 ]; then
    echo "内容" | mail -s "主题" xujun1270@qq.com
fi
